#pragma once

#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include <iostream>
#include <time.h>
#include <string.h>
typedef int HeapDateType;
typedef struct Heap
{
  HeapDateType* a;
  int size;
  int capacity;
}Heap;

void HeapInit(Heap* php);
void HeapPush(Heap* php,HeapDateType x);
void HeapDestroy(Heap* php);
void HeapPop(Heap* php);
HeapDateType HeapTop(Heap* php);
int HeapSize(Heap* php);
bool HeapEmpty(Heap* php);
void HeapPrint(Heap* php);
void AdjustUp(HeapDateType* a,int child);
void AdjustDown(HeapDateType* a,int n, int parent);
HeapDateType HeapTop(Heap* php);
void Swap(HeapDateType* child, HeapDateType* parent);
